import { BasicStatus, PermissionType } from '@/types/enum';

/**
 * Organization data mock
 */
export const ORG_LIST = [
  {
    id: '1',
    name: 'East China Branch',
    status: 'enable',
    desc: '',
    order: 1,
    children: [
      { id: '1-1', name: 'R&D Department', status: 'disable', desc: '', order: 1 },
      { id: '1-2', name: 'Marketing Department', status: 'enable', desc: '', order: 2 },
      { id: '1-3', name: 'Finance Department', status: 'enable', desc: '', order: 3 },
    ],
  },
  {
    id: '2',
    name: 'South China Branch',
    status: 'enable',
    desc: '',
    order: 2,
    children: [
      { id: '2-1', name: 'R&D Department', status: 'disable', desc: '', order: 1 },
      { id: '2-2', name: 'Marketing Department', status: 'enable', desc: '', order: 2 },
      { id: '2-3', name: 'Finance Department', status: 'enable', desc: '', order: 3 },
    ],
  },
];

/**
 * User permission mock
 */
const DASHBOARD_PERMISSION = {
  id: '9100714781927703',
  parentId: '',
  label: 'sys.menu.dashboard',
  name: 'Dashboard',
  icon: 'ic-analysis',
  type: PermissionType.CATALOGUE,
  route: 'dashboard',
  order: 1,
  children: [
    {
      id: '8426999229400979',
      parentId: '9100714781927703',
      label: 'sys.menu.workbench',
      name: 'Workbench',
      type: PermissionType.MENU,
      route: 'workbench',
      component: '/dashboard/workbench/index.tsx',
    },
    {
      id: '9710971640510357',
      parentId: '9100714781927703',
      label: 'sys.menu.analysis',
      name: 'Analysis',
      type: PermissionType.MENU,
      route: 'analysis',
      component: '/dashboard/analysis/index.tsx',
    },
  ],
};
const MANAGEMENT_PERMISSION = {
  id: '0901673425580518',
  parentId: '',
  label: 'sys.menu.management',
  name: 'Management',
  icon: 'ic-management',
  type: PermissionType.CATALOGUE,
  route: 'management',
  order: 2,
  children: [
    {
      id: '2781684678535711',
      parentId: '0901673425580518',
      label: 'sys.menu.user.index',
      name: 'User',
      type: PermissionType.CATALOGUE,
      route: 'user',
      children: [
        {
          id: '4754063958766648',
          parentId: '2781684678535711',
          label: 'sys.menu.user.profile',
          name: 'Profile',
          type: PermissionType.MENU,
          route: 'profile',
          component: '/management/user/profile/index.tsx',
        },
        {
          id: '2516598794787938',
          parentId: '2781684678535711',
          label: 'sys.menu.user.account',
          name: 'Account',
          type: PermissionType.MENU,
          route: 'account',
          component: '/management/user/account/index.tsx',
        },
      ],
    },
    {
      id: '0249937641030250',
      parentId: '0901673425580518',
      label: 'sys.menu.system.index',
      name: 'System',
      type: PermissionType.CATALOGUE,
      route: 'system',
      children: [
        {
          id: '1985890042972842',
          parentId: '0249937641030250',
          label: 'sys.menu.system.organization',
          name: 'Organization',
          type: PermissionType.MENU,
          route: 'organization',
          component: '/management/system/organization/index.tsx',
        },
        {
          id: '4359580910369984',
          parentId: '0249937641030250',
          label: 'sys.menu.system.permission',
          name: 'Permission',
          type: PermissionType.MENU,
          route: 'permission',
          component: '/management/system/permission/index.tsx',
        },
        {
          id: '1689241785490759',
          parentId: '0249937641030250',
          label: 'sys.menu.system.role',
          name: 'Role',
          type: PermissionType.MENU,
          route: 'role',
          component: '/management/system/role/index.tsx',
        },
        {
          id: '0157880245365433',
          parentId: '0249937641030250',
          label: 'sys.menu.system.user',
          name: 'User',
          type: PermissionType.MENU,
          route: 'user',
          component: '/management/system/user/index.tsx',
        },
        {
          id: '0157880245365434',
          parentId: '0249937641030250',
          label: 'sys.menu.system.user_detail',
          name: 'User Detail',
          type: PermissionType.MENU,
          route: 'user/:id',
          component: '/management/system/user/detail.tsx',
          hide: true,
        },
      ],
    },
  ],
};
const FUNCTIONS_PERMISSION = {
  id: '8132044808088488',
  parentId: '',
  label: 'sys.menu.functions',
  name: 'functions',
  icon: 'solar:plain-2-bold-duotone',
  type: PermissionType.CATALOGUE,
  route: 'functions',
  order: 4,
  children: [
    {
      id: '3667930780705750',
      parentId: '8132044808088488',
      label: 'sys.menu.clipboard',
      name: 'Clipboard',
      type: PermissionType.MENU,
      route: 'clipboard',
      component: '/functions/clipboard/index.tsx',
    },
    {
      id: '3667930780705751',
      parentId: '8132044808088488',
      label: 'sys.menu.token_expired',
      name: 'Token Expired',
      type: PermissionType.MENU,
      route: 'token-expired',
      component: '/functions/token-expired/index.tsx',
    },
  ],
};
const MENU_LEVEL_PERMISSION = {
  id: '0194818428516575',
  parentId: '',
  label: 'sys.menu.menulevel.index',
  name: 'Menu Level',
  icon: 'ic-menulevel',
  type: PermissionType.CATALOGUE,
  route: 'menu-level',
  order: 5,
  children: [
    {
      id: '0144431332471389',
      parentId: '0194818428516575',
      label: 'sys.menu.menulevel.1a',
      name: 'Menu Level 1a',
      type: PermissionType.MENU,
      route: 'menu-level-1a',
      component: '/menu-level/menu-level-1a/index.tsx',
    },
    {
      id: '7572529636800586',
      parentId: '0194818428516575',
      label: 'sys.menu.menulevel.1b.index',
      name: 'Menu Level 1b',
      type: PermissionType.CATALOGUE,
      route: 'menu-level-1b',
      children: [
        {
          id: '3653745576583237',
          parentId: '7572529636800586',
          label: 'sys.menu.menulevel.1b.2a',
          name: 'Menu Level 2a',
          type: PermissionType.MENU,
          route: 'menu-level-2a',
          component: '/menu-level/menu-level-1b/menu-level-2a/index.tsx',
        },
        {
          id: '4873136353891364',
          parentId: '7572529636800586',
          label: 'sys.menu.menulevel.1b.2b.index',
          name: 'Menu Level 2b',
          type: PermissionType.CATALOGUE,
          route: 'menu-level-2b',
          children: [
            {
              id: '4233029726998055',
              parentId: '4873136353891364',
              label: 'sys.menu.menulevel.1b.2b.3a',
              name: 'Menu Level 3a',
              type: PermissionType.MENU,
              route: 'menu-level-3a',
              component: '/menu-level/menu-level-1b/menu-level-2b/menu-level-3a/index.tsx',
            },
            {
              id: '3298034742548454',
              parentId: '4873136353891364',
              label: 'sys.menu.menulevel.1b.2b.3b',
              name: 'Menu Level 3b',
              type: PermissionType.MENU,
              route: 'menu-level-3b',
              component: '/menu-level/menu-level-1b/menu-level-2b/menu-level-3b/index.tsx',
            },
          ],
        },
      ],
    },
  ],
};
const ERRORS_PERMISSION = {
  id: '9406067785553476',
  parentId: '',
  label: 'sys.menu.error.index',
  name: 'Error',
  icon: 'bxs:error-alt',
  type: PermissionType.CATALOGUE,
  route: 'error',
  order: 6,
  children: [
    {
      id: '8557056851997154',
      parentId: '9406067785553476',
      label: 'sys.menu.error.403',
      name: '403',
      type: PermissionType.MENU,
      route: '403',
      component: '/sys/error/Page403.tsx',
    },
    {
      id: '5095669208159005',
      parentId: '9406067785553476',
      label: 'sys.menu.error.404',
      name: '404',
      type: PermissionType.MENU,
      route: '404',
      component: '/sys/error/Page404.tsx',
    },
    {
      id: '0225992135973772',
      parentId: '9406067785553476',
      label: 'sys.menu.error.500',
      name: '500',
      type: PermissionType.MENU,
      route: '500',
      component: '/sys/error/Page500.tsx',
    },
  ],
};
const WORK_PERMISSION = [
  {
    id: '0941594969900758',
    parentId: '',
    label: 'sys.menu.datasets',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'datasets',
    component: '/datasets/index.tsx',
    hide: true,
  },
  {
    id: '0941594969900757',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/workflow',
    component: '/workflow/index.tsx',
    hide: true,
  },
  {
    id: '0941594961234760',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'datasets/manage',
    component: '/dataset-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/report',
    component: '/report/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/report/:id',
    component: '/report/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/report',
    component: '/report/indexv2.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/report/:id',
    component: '/report/indexv2.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900762',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/chat',
    component: '/app-qa/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900762',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/test',
    component: '/app-test/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900763',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/ehuman/:id/:mid',
    component: '/chat/MetaHuman.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900763',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/ehuman/:id/:sid/:did/:mid',
    component: '/chat/MetaHuman.tsx',
    hide: true,
    hideHeader: true,
  },
  // {
  //   id: '0157880245365435',
  //   parentId: '',
  //   label: 'sys.menu.workbench',
  //   name: 'User Detail',
  //   type: PermissionType.MENU,
  //   route: 'apps/chat/:id/:sid/:did/:mid',
  //   component: '/chat/index.tsx',
  //   hide: true,
  //   hideHeader: true,
  // },
  {
    id: '0157880245365435',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/:type/:id/:sid/:did/:mid',
    component: '/chat/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0157880245365436',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/:type/:id/:sid',
    component: '/chat/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '1157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/manage/:id',
    component: '/app-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '1157880245366499',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Share Link',
    type: PermissionType.MENU,
    route: 'share/link',
    component: '/share-link-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  // {
  //   id: '1157880245365438',
  //   parentId: '',
  //   label: 'sys.menu.workbench',
  //   name: 'User Detail',
  //   type: PermissionType.MENU,
  //   route: 'extension/manage',
  //   component: '/extension-manage/index.tsx',
  //   hide: true,
  //   hideHeader: true,
  // },
  {
    id: '1157880245365438',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'user/manage',
    component: '/user-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  // {
  //   id: '2157880245365437',
  //   parentId: '',
  //   label: 'sys.menu.workbench',
  //   name: 'User Detail',
  //   type: PermissionType.MENU,
  //   route: 'apps/permission',
  //   component: '/permission/index.tsx',
  //   hide: true,
  //   hideHeader: true,
  // },
  {
    id: '0157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'auth',
    component: '/auth/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '1157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'management',
    component: '/management/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'history',
    component: '/history-chat/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365438',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'homepage',
    component: '/homepage/index.tsx',
    hide: true,
    hideHeader: true,
  },

  {
    id: '2157880245365438',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'homepage2',
    component: '/app-qa/index.tsx',
    hide: true,
    hideHeader: true,
  },

  {
    id: '2157880245365440',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'app/page',
    component: '/app-page/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365441',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'app/application',
    component: '/app-application/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365442',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'fusion',
    component: '/app-fusion/index.tsx',
    hide: true,
    hideHeader: true,
  },

  {
    id: '1157880245365499',
    parentId: '',
    label: 'sys.menu.role',
    name: 'Role Manage',
    icon: 'icon-park-solid--people',
    type: PermissionType.MENU,
    route: 'role/manage',
    component: '/role-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365437',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'apps/permission',
    component: '/permission/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365438',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'apps/permission-manage',
    component: '/permission-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157880245365438',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'apps/knowledge-manage',
    component: '/knowledge-manage/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2587880245365451',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: 'apps/singleSign/:id',
    component: '/single-sign/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157660245365139',
    parentId: '',
    label: 'sys.menu.DataConnector',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'app/workflow',
    component: '/app/detail/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '0941594969900759',
    parentId: '',
    label: 'sys.menu.app.orchestration',
    name: 'App Orchestration',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/orchestration',
    component: '/app-orchestration/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157660245365223',
    parentId: '',
    label: 'sys.menu.app.orchestration',
    name: 'App Orchestration',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'mcp/orchestration',
    component: '/mcp-orchestration/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900760',
    parentId: '',
    label: 'sys.menu.app.orchestration',
    name: 'App Orchestration',
    icon: 'ic_blank',
    type: PermissionType.MENU,
    route: 'apps/viewOrchestration',
    component: '/view-app-orchestration/index.tsx',
    hide: true,
    hideHeader: true,
  },
];

/**
 * 知识治理
 */
export const KNOW_BASE_PERMISSION = [
  {
    id: '2157660245365437',
    order: 2,
    parentId: '',
    label: 'sys.menu.knowgov',
    name: 'User Detail',
    icon: 'home-widgets',
    type: PermissionType.MENU,
    route: 'know-gov',
    component: '/know-gov/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '2157660245365438',
    parentId: '',
    label: 'sys.menu.knowgov',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'know-gov/govern',
    component: '/know-gov/sub-pages/govern/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157660245365439',
    parentId: '',
    label: 'sys.menu.knowgov',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'know-gov/entry',
    component: '/know-gov/sub-pages/entry/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157660245365439',
    parentId: '',
    label: 'sys.menu.knowgov',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'know-gov/document',
    component: '/know-gov/sub-pages/document/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '2157660245365439',
    parentId: '',
    label: 'sys.menu.knowgov',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'know-gov/approval',
    component: '/know-gov/sub-pages/approval/index.tsx',
    hide: true,
    hideHeader: true,
  },
];

export const DEBUG_PERMISSION = [
  {
    id: '2157660245365437',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'components-demo',
    component: '/components-demo/index.tsx',
    hide: false,
    hideHeader: true,
  },
];

/**
 * 知识运营平台API权限
 */
export const KNOW_API_PERMISSION = [
  {
    id: '0941594961234760',
    parentId: '',
    label: 'sys.menu.api',
    name: 'Api',
    icon: 'icon-api',
    type: PermissionType.MENU,
    route: 'datasets/api',
    component: '/api-manage/index.tsx',
    hide: false,
    hideHeader: true,
  },
];

/**
 * 知识运营平台应用管理
 */
export const KNOW_EXTENSION_PERMISSION = [
  {
    id: '1157880245365438',
    parentId: '',
    label: 'sys.menu.extension',
    name: 'User Detail',
    icon: 'ri--apps-3-fill',
    type: PermissionType.MENU,
    route: 'extension/manage',
    component: '/extension-manage/index.tsx',
    hide: false,
    hideHeader: true,
  },
];

/**
 * 知识库审批管理
 */
export const KNOW_BASE_APPROVAL_PERMISSION = [
  {
    id: '2157660245365140',
    parentId: '',
    label: 'sys.menu.knowledgeBaseApproval',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'datasets/approval',
    component: '/knowledge-base-approval/index.tsx',
    hide: false,
    hideHeader: true,
  },
];

/**
 * 知识运营平台路由权限
 */
export const KNOW_PAGE_PERMISSION = [
  {
    id: '0941594969900759',
    parentId: '',
    label: 'sys.menu.workbench',
    name: 'Disabled',
    icon: 'mdi--folder-zip',
    type: PermissionType.MENU,
    route: 'datasets/detail',
    component: '/dataset-detail/index.tsx',
    hide: true,
    hideHeader: true,
  },
  {
    id: '0941594969900760',
    order: 1,
    parentId: '',
    label: 'sys.menu.datasets',
    name: 'Dataset',
    icon: 'mdi--folder-zip',
    type: PermissionType.MENU,
    route: 'datasets/list',
    component: '/datasets/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '2157990245365437',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'datasets/collection/detail',
    component: '/collection-detail/index.tsx',
    hide: true,
    hideHeader: true,
  },

  {
    id: '2157660245365139',
    parentId: '',
    label: 'sys.menu.DataConnector',
    name: 'User Detail',
    icon: 'ic-management',
    type: PermissionType.MENU,
    route: 'know-gov/connector',
    component: '/know-gov/sub-pages/connector/index.tsx',
    hide: false,
    hideHeader: true,
  },
];
/**
 * 知识运营平台路由权限
 */
export const KNOW_PERMISSION = [...KNOW_BASE_PERMISSION];

export const DATASET_PERMISSION = [...KNOW_PAGE_PERMISSION];

export const PERMISSION_LIST = [...WORK_PERMISSION, ...DEBUG_PERMISSION];

export const WORK_BASE_PERMISSION = [
  {
    id: '2157880245365439',
    parentId: '',
    label: 'sys.menu.workbench',
    icon: 'menu_home',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: '',
    order: 1,
    component: '/workbench/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '21576602453651435',
    parentId: '',
    label: 'sys.menu.AINav',
    name: 'User Detail',
    icon: 'menu-ainav',
    type: PermissionType.MENU,
    route: 'aiNav',
    component: '/ai-nav/index.tsx',
    hide: false,
    order: 2,
    hideHeader: true,
  },
  {
    id: '2157660245365140',
    parentId: '',
    label: 'sys.menu.appReviewCenter',
    name: 'User Detail',
    icon: 'menu_approve',
    type: PermissionType.CATALOGUE,
    route: 'appReviewCenter',
    order: 3,
    children: [
      {
        id: '21576602453651401',
        parentId: '2157660245365140',
        label: 'sys.menu.appReview',
        name: 'User Detail',
        icon: 'menu_agent',
        type: PermissionType.MENU,
        route: 'app-review',
        component: '/app-review/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '21576602453651402',
        parentId: '2157660245365140',
        label: 'sys.menu.knowledgeBaseApproval',
        name: 'User Detail',
        icon: 'ic-management',
        type: PermissionType.MENU,
        route: 'datasets/knowledge-base-approval',
        component: '/knowledge-base-approval/index.tsx',
        hide: false,
        hideHeader: true,
      },
      // {
      //   id: '21576602453651403',
      //   parentId: '2157660245365140',
      //   label: 'sys.menu.approval',
      //   name: 'User Detail',
      //   icon: 'menu_problemaudit',
      //   type: PermissionType.MENU,
      //   route: 'datasets/approval',
      //   component: '/know-gov/sub-pages/approval/index.tsx',
      //   hide: false,
      //   hideHeader: true,
      // },
    ],
  },
  {
    id: '21576602453651423',
    parentId: '',
    label: 'sys.menu.messageCenter',
    name: 'User Detail',
    icon: 'menu_message',
    type: PermissionType.MENU,
    order: 4,
    route: 'messageCenter',
    component: '/message-center/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '21576602453651422',
    parentId: '',
    label: 'sys.menu.behaviorLog',
    name: 'User Detail',
    icon: 'ai-menu-log',
    type: PermissionType.MENU,
    route: 'behavior-log',
    order: 5,
    component: '/behavior-log/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '21576602453651423',
    parentId: '',
    label: 'sys.menu.modelManage',
    name: 'User Detail',
    icon: 'model',
    type: PermissionType.MENU,
    route: 'modelManage',
    component: '/modelManage/index.tsx',
    hide: false,
    order: 6,
    hideHeader: true,
  },
  {
    id: '21576602453651424',
    parentId: '',
    label: 'sys.menu.metahumanManage',
    name: 'User Detail',
    icon: 'metahuman',
    type: PermissionType.MENU,
    route: 'metahumanManage',
    component: '/metahuman-manage/index.tsx',
    hide: false,
    order: 6,
    hideHeader: true,
  },
  //   {
  //   id: '21576602453651423',
  //   parentId: '2157660245365141',
  //   label: 'sys.menu.modelManage',
  //   name: 'User Detail',
  //   icon: 'menu_entry',
  //   type: PermissionType.MENU,
  //   route: 'modelManage',
  //   component: '/modelManage/index.tsx',
  //   hide: false,
  //   order:5,
  //   hideHeader: true,
  // },
  // 工具管理
  {
    id: '2157660245365220',
    parentId: '',
    label: 'sys.menu.tools',
    name: 'User Detail',
    icon: 'menu_tool',
    type: PermissionType.CATALOGUE,
    route: 'tools',
    order: 7,
    children: [
      {
        id: '2157660245365221',
        parentId: '2157660245365220',
        label: 'sys.menu.pluginCenter',
        name: 'User Detail',
        icon: 'menu_plugin',
        type: PermissionType.MENU,
        route: 'pluginCenter',
        component: '/plugin-center/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '2157660245365222',
        parentId: '2157660245365220',
        label: 'sys.menu.mcpCenter',
        name: 'User Detail',
        icon: 'menu_mcp',
        type: PermissionType.MENU,
        route: 'mcpCenter',
        component: '/mcp-center/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '2157660245365141',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'menu_permission',
    type: PermissionType.CATALOGUE,
    route: 'permission',
    order: 8,
    children: [
      {
        id: '215766024536512132',
        parentId: '2157660245365141',
        label: 'sys.menu.appManagement',
        name: 'User Detail',
        icon: 'menu_application_permiss',
        type: PermissionType.MENU,
        route: 'appManage',
        component: '/app-permission-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '2157660245365140',
        parentId: '2157660245365141',
        label: 'sys.menu.orgManagement',
        name: 'User Detail',
        icon: 'ai-menu-organization',
        type: PermissionType.MENU,
        route: 'organizational-manage',
        component: '/organizational-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '2157660245365142',
    parentId: '',
    label: 'sys.menu.documentManagement',
    name: 'User Detail',
    icon: 'menu_document',
    type: PermissionType.CATALOGUE,
    route: 'documentManagement',
    order: 9,
    children: [
      {
        id: '2157660245365151',
        parentId: '2157660245365142',
        label: 'sys.menu.docTypeManagement',
        name: 'User Detail',
        icon: 'ai-menu-documenttype',
        type: PermissionType.MENU,
        route: 'document-type-manage',
        component: '/document-type-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '21576602453651452',
        parentId: '2157660245365142',
        label: 'sys.menu.termManage',
        name: 'User Detail',
        icon: 'menu_entry',
        type: PermissionType.MENU,
        route: 'entry',
        component: '/know-gov/sub-pages/entry/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '21576602453651434',
    parentId: '',
    label: 'sys.menu.sso',
    name: 'User Detail',
    icon: 'ai-menu-login',
    type: PermissionType.MENU,
    route: 'singleSign',
    component: '/single-sign/index.tsx',
    hide: false,
    order: 10, //时刻保持是最后一个
    hideHeader: true,
  },
];


export const WORK_BASE_PERMISSION_V1 = [
  {
    id: '2157880245365439',
    parentId: '',
    label: 'sys.menu.workbench',
    icon: 'menu_home',
    name: 'User Detail',
    type: PermissionType.MENU,
    route: '',
    order: 1,
    component: '/workbench/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '2157660245365140',
    parentId: '',
    label: 'sys.menu.appReviewCenter',
    name: 'User Detail',
    icon: 'menu_approve',
    type: PermissionType.CATALOGUE,
    route: 'appReviewCenter',
    order: 3,
    children: [
      {
        id: '21576602453651401',
        parentId: '2157660245365140',
        label: 'sys.menu.appReview',
        name: 'User Detail',
        icon: 'menu_agent',
        type: PermissionType.MENU,
        route: 'app-review',
        component: '/app-review/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '21576602453651402',
        parentId: '2157660245365140',
        label: 'sys.menu.knowledgeBaseApproval',
        name: 'User Detail',
        icon: 'ic-management',
        type: PermissionType.MENU,
        route: 'datasets/knowledge-base-approval',
        component: '/knowledge-base-approval/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '21576602453651403',
        parentId: '2157660245365140',
        label: 'sys.menu.approval',
        name: 'User Detail',
        icon: 'menu_problemaudit',
        type: PermissionType.MENU,
        route: 'datasets/approval',
        component: '/know-gov/sub-pages/approval/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '21576602453651423',
    parentId: '',
    label: 'sys.menu.messageCenter',
    name: 'User Detail',
    icon: 'menu_message',
    type: PermissionType.MENU,
    order: 4,
    route: 'messageCenter',
    component: '/message-center/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '21576602453651422',
    parentId: '',
    label: 'sys.menu.behaviorLog',
    name: 'User Detail',
    icon: 'ai-menu-log',
    type: PermissionType.MENU,
    route: 'behavior-log',
    order: 5,
    component: '/behavior-log/index.tsx',
    hide: false,
    hideHeader: true,
  },
  {
    id: '21576602453651423',
    parentId: '',
    label: 'sys.menu.modelManage',
    name: 'User Detail',
    icon: 'model',
    type: PermissionType.MENU,
    route: 'modelManage',
    component: '/modelManage/index.tsx',
    hide: false,
    order: 6,
    hideHeader: true,
  },
  {
    id: '2157660245365141',
    parentId: '',
    label: 'sys.menu.permission',
    name: 'User Detail',
    icon: 'menu_permission',
    type: PermissionType.CATALOGUE,
    route: 'permission',
    order: 8,
    children: [
      {
        id: '215766024536512132',
        parentId: '2157660245365141',
        label: 'sys.menu.appManagement',
        name: 'User Detail',
        icon: 'menu_application_permiss',
        type: PermissionType.MENU,
        route: 'appManage',
        component: '/app-permission-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '2157660245365140',
        parentId: '2157660245365141',
        label: 'sys.menu.orgManagement',
        name: 'User Detail',
        icon: 'ai-menu-organization',
        type: PermissionType.MENU,
        route: 'organizational-manage',
        component: '/organizational-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '2157660245365142',
    parentId: '',
    label: 'sys.menu.documentManagement',
    name: 'User Detail',
    icon: 'menu_document',
    type: PermissionType.CATALOGUE,
    route: 'documentManagement',
    order: 9,
    children: [
      {
        id: '2157660245365151',
        parentId: '2157660245365142',
        label: 'sys.menu.docTypeManagement',
        name: 'User Detail',
        icon: 'ai-menu-documenttype',
        type: PermissionType.MENU,
        route: 'document-type-manage',
        component: '/document-type-manage/index.tsx',
        hide: false,
        hideHeader: true,
      },
      {
        id: '21576602453651452',
        parentId: '2157660245365142',
        label: 'sys.menu.termManage',
        name: 'User Detail',
        icon: 'menu_entry',
        type: PermissionType.MENU,
        route: 'entry',
        component: '/know-gov/sub-pages/entry/index.tsx',
        hide: false,
        hideHeader: true,
      },
    ],
  },
  {
    id: '21576602453651434',
    parentId: '',
    label: 'sys.menu.sso',
    name: 'User Detail',
    icon: 'ai-menu-login',
    type: PermissionType.MENU,
    route: 'singleSign',
    component: '/single-sign/index.tsx',
    hide: false,
    order: 10, //时刻保持是最后一个
    hideHeader: true,
  },
];

/**
 * User role mock
 */
const ADMIN_ROLE = {
  id: '4281707933534332',
  name: '访客',
  code: 'guest',
  label: '访客',
  status: BasicStatus.ENABLE,
  order: 1,
  desc: 'guest',
  permission: PERMISSION_LIST,
};
const TEST_ROLE = {
  id: '9931665660771476',
  name: 'Test',
  label: 'test',
  code: 'test',
  status: BasicStatus.ENABLE,
  order: 2,
  desc: 'test',
  permission: [DASHBOARD_PERMISSION, FUNCTIONS_PERMISSION],
};
const TIANGONG_ROLE = {
  id: 'tiangong-role-001',
  name: '天工',
  label: '天工',
  code: 'tiangong',
  status: BasicStatus.ENABLE,
  order: 3,
  desc: '天工角色',
  permission: [DASHBOARD_PERMISSION, FUNCTIONS_PERMISSION],
  dataVisibility: {
    canViewAllData: true,
    canViewSensitiveData: true,
  },
  featurePermissions: {
    canManageWorkflow: true,
    canViewAnalytics: true,
    canAccessAdvancedFeatures: true,
  },
};
export const ROLE_LIST = [ADMIN_ROLE, TEST_ROLE, TIANGONG_ROLE];

/**
 * User data mock
 */
export const DEFAULT_USER = {
  // id: 'b34719e1-ce46-457e-9575-99505ecee828',
  username: 'root',
  role: ADMIN_ROLE,
  permissions: ADMIN_ROLE.permission,
};
export const TEST_USER = {
  // id: 'efaa20ea-4dc5-47ee-a200-8a899be29494',
  username: 'test',
  role: TEST_ROLE,
  permissions: TEST_ROLE.permission,
};
export const TIANGONG_USER = {
  id: 'tiangong-user-001',
  username: 'tiangong',
  name: '天工用户',
  email: 'tiangong@example.com',
  role: TIANGONG_ROLE,
  permissions: TIANGONG_ROLE.permission,
  dataVisibility: TIANGONG_ROLE.dataVisibility,
  featurePermissions: TIANGONG_ROLE.featurePermissions,
};
export const USER_LIST = [DEFAULT_USER, TEST_USER, TIANGONG_USER];
